import request from "@/utils/request"

// 新增app版本
export function addAppVersions(data) {
    return request({
        url: `/api/app/packageVersion`,
        method: "post",
        baseURL: public_config.control_api,
        data
    })
}

// 更新app版本
export function putAppVersions(data) {
    return request({
        url: `/api/app/packageVersion`,
        method: "put",
        baseURL: public_config.control_api,
        data
    })
}

// 删除app版本
export function delAppVersions(data) {
    return request({
        url: `/api/app/packageVersion/delete`,
        method: "post",
        baseURL: public_config.control_api,
        data
    })
}

// 获取版本下拉
export function appDropDownList(data) {
    return request({
        url: `/api/app/packageVersion/dropdownList`,
        method: "get",
        baseURL: public_config.control_api,
        data
    })
}

// 获取app版本详情
export function detailAppVersions(params) {
    return request({
        url: `/api/app/packageVersion/`,
        method: "get",
        baseURL: public_config.control_api,
        params
    })
}


//版本发布
export function publishAppVersions(data) {
    return request({
        url: `/api/app/packageVersion/publish`,
        method: "post",
        baseURL: public_config.control_api,
        data
    })
}
// 获取app版本列表
export function getAppVersions(params) {
    return request({
        url: `/api/app/packageVersion/search`,
        method: "get",
        baseURL: public_config.control_api,
        params
    })
}